package com.wenresearch.orion.demoapp.screen;

import net.rim.device.api.system.Bitmap;
import net.rim.device.api.ui.UiApplication;
import net.rim.device.api.ui.container.MainScreen;

import com.wenresearch.orion.components.AbstractSplashScreen;

/**
 * Example of custom splash screen
 * @author Ali Irawan (boylevantz@gmail.com)
 * @version 1.0
 */
public class MySplashScreen extends AbstractSplashScreen {

	/**
	 * Create splash screen
	 * @param ui application instance
	 * @param next screen to be shown after splash screen
	 */
	public MySplashScreen(UiApplication ui, MainScreen next) {
		super(ui, next);
	}

	/**
	 * Return the image to be shown
	 */
	public Bitmap getSplashBitmap() {
		// Look bitmap in "res/img" folder
		return Bitmap.getBitmapResource("img/splash.png");
	}

	/**
	 * Implements splash interval in milliseconds
	 */
	public long getTimerInterval() {
		// 3 seconds = 3000 milliseconds
		return 3000;
	}

}
